<!-- 首页 -->
<template>
  <el-container>
    <!-- 左侧菜单栏 -->
    <el-aside width="200px">
      <SideMenu></SideMenu>
    </el-aside>
    <el-container>
      <!-- 头部 -->
      <el-header>
        <Header></Header>
      </el-header>
      <!-- 中心内容 -->
      <el-main>
        <!-- 子路由 -->
        <Tabs></Tabs>
        <div style="margin: 0 15px">
          <router-view></router-view>
        </div>
      </el-main>
    </el-container>
  </el-container>
</template>

<script>
//这里可以导入其他文件(比如:组件、工具js、)
//例如：import 组件名 from '组件路径'
import SideMenu from "./inc/SideMenu.vue";
import Header from "./inc/Header.vue";
import Tabs from "./inc/Tabs.vue";
export default {
  name: "Home",
  //import引入的组件需要注入到对象中才能使用
  data() {
    return {
      user: "超级管理员"
    };
  },

  //组件
  components: { SideMenu, Header, Tabs },

  computed: {},

  // mounted: {},

  methods: {}
  //生命周期 - 创建完成（可以访问当前this实例）
  // created: {}
};
</script>

<style scoped>
.el-container {
  height: 100%;
  margin: 0;
  padding: 0;
}
.el-header {
  background-color: rgb(103, 179, 164);
  color: #333;
  text-align: center;
  line-height: 60px;
}

.el-dropdown-link {
  cursor: pointer;
  color: #409eff;
}

.header-right {
  float: right;
  width: 230px;
  height: 100%;
  display: flex;
  align-items: center;
  /* flex-direction: column; */
  justify-content: center;
}

.el-aside {
  background-color: rgb(86, 92, 100);
  /* background-color: royalblue; */
  color: #333;
  /* text-align: center; */
  line-height: 200px;
}

.el-main {
  /* background-color: #e9eef3; */
  color: #333;
  /* text-align: center; */
  /* line-height: 160px; */
  padding: 0px;
}

/* -------------头部---------------- */
.el-dropdown-link {
  cursor: pointer;
  color: #409eff;
}
.el-icon-arrow-down {
  font-size: 12px;
}

.el-menu-vertical-demo /deep/ .el-submenu__title {
  display: flex;
  align-items: center;
  justify-content: flex-start;
}

.el-menu {
  border-right: 0px;
}
</style>
